<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    .box1{
      background-color: #bfa;
      width: 200px;
      height: 100px;
      /* overflow: scroll; */
      overflow:auto;
    }
    .box2{
      background-color: orange;
      /* height: 200px; */
    }
  </style>
</head>
<body>
  <div class="box1">box1
    <div class="box2">box2 Lorem ipsum dolor sit amet consectetur adipisicing elit. Explicabo possimus, ducimus nulla veniam itaque, architecto aspernatur error expedita magnam molestias enim eum? Nemo porro, officiis totam esse excepturi cumque quidem.</div>
  </div>
</body>
</html>